<div class="page-body">
    <a class="btn btn-default purple" href="{:U('add')}" style="margin-bottom: 15px;"><i class="fa fa-plus"></i>
        新增活动
    </a>
    <div class="row">
        <div class="col-xs-12 col-md-12">
            <div class="widget">
                <div class="widget-header ">
                    <span class="widget-caption">活动列表</span>
                    <div class="widget-buttons">
                        <a href="#" data-toggle="maximize">
                            <i class="fa fa-expand"></i>
                        </a>
                        <a href="#" data-toggle="collapse">
                            <i class="fa fa-minus"></i>
                        </a>
                        <a href="#" data-toggle="dispose">
                            <i class="fa fa-times"></i>
                        </a>
                    </div>
                </div>
                <div class="widget-body">
                    <div class="table-toolbar">
                        <form method="get" action="{:U('index')}" class="form-inline" role="form">
                            <div class="form-group">
                            <span class="input-icon" style="width: 200px;">
                                <input type="text" class="form-control input-sm" placeholder="活动名"
                                       name="keywords" value="{$Think.get.keywords}">
                                <i class="glyphicon glyphicon-search blue"></i>
                            </span>
                            </div>
                            <button type="submit" class="btn btn-info">搜索</button>

                            <a href="{:U('export')}" class="btn btn-danger">活动列表导出</a>
                        </form>
                    </div>
                    <table class="table table-striped table-hover">
                        <thead>
                        <tr>
                            <th>
                                ID
                            </th>
                            <th>
                                活动名
                            </th>
                            <th>
                                报名时间
                            </th>
                            <th>
                                活动时间
                            </th>
                            <th>
                                人数
                            </th>
                            <th>
                                费用
                            </th>
                            <th>
                                {:C('act_freenum_name')}
                            </th>
                            <th>
                                内容
                            </th>
                            <th></th>
                        </tr>
                        </thead>

                        <tbody>
                        <foreach name="data" item="v">
                            <tr>
                                <td>
                                    {$v.activity_id}
                                </td>
                                <td>
                                    {$v.title}
                                    <br>
                                    <empty  name="v.a_logo">
                                        暂无图片
                                        <else/>
                                        <img src="{$v.a_logo}" width="100">
                                    </empty >
                                </td>
                                <td>
                                    开始：{$v.apply_start}<br>
                                    结束：{$v.apply_end}
                                </td>
                                <td>
                                    开始：{$v.activity_start}<br>
                                    结束：{$v.activity_end}
                                </td>
                                <td>
                                    剩余：{$v.apply_num}<br>
                                    总计：{$v.apply_total}
                                </td>
                                <td>
                                    报名费：{$v.price_apply}<br>
                                    材料费：{$v.price_material}
                                </td>
                                <td>{$v.num_deduct}</td>
                                <td>{$v.content|substr=0,100}</td>
                                <td>
                                    <a class="btn btn-danger btn-xs del-btn" href="javascript:;"
                                       data-href="{:U('del',array('activity_id'=>$v['activity_id']))}"><i
                                            class="fa fa-trash-o"></i></a>
                                    <a class="btn btn-info btn-xs"
                                       href="{:U('edit',array('activity_id'=>$v['activity_id']))}">
                                        <i class="fa fa-edit"></i> 编辑
                                    </a>
                                </td>
                            </tr>
                        </foreach>
                        </tbody>
                    </table>
                    {$page}
                    <form class="form-inline" method="post">
                        <div class="form-group">
                            <div class="input-group">
                                <div class="input-group-addon">设置页码</div>
                                <input class="form-control" type="text" placeholder="" name="p" value="{$Think.get.p}" style="width: 60px;">
                            </div>
                        </div>
                    </form>
                </div>
            </div>
        </div>
    </div>
</div>